package 笔记.设计模式.工厂模式;

/**
 * @author chenhailong
 * @ClassName: Text
 * @Description: 测试工厂   优点：关注模具整体结构，不关心内部怎么实现。易于拓展，只需增加一个工厂类
 *                        缺点：过多的产品线，工厂类和实现都会增加
 * @date 2021/6/29 20:28
 * @Version 1.0
 */
public class Text {

    public static void main(String[] args) {
        FactoryBean factoryBean = new FactoryBean();
        Factory factroyone = factoryBean.getBean("factoryone");
        Factory factroytwo = factoryBean.getBean("factorytwo");
        factroyone.factory();
        factroytwo.factory();
    }
}
